from django.contrib.syndication.feeds import Feed
from content.models import Post

import settings

class LatestEntries(Feed):
    title = "%s news feed" % settings.SITE_NAME
    link = "/"
    description = "Latest news and blog posts at %s" % settings.SITE_NAME

    def items(self):
        return Post.objects.order_by('-date')[:5]

